CCM-7478: Enable Test Coverage Reporting in Sonar#1007
Conversation
|
This branch is work on a ticket in the NHS Digital APM JIRA Project. Here's a handy link to the ticket: CCM-7478 |
|
This branch is work on a ticket in the NHS Digital APM JIRA Project. Here's a handy link to the ticket: CCM-7478 |
|
This branch is work on a ticket in the NHS Digital APM JIRA Project. Here's a handy link to the ticket: CCM-7478 |
|
This branch is work on a ticket in the NHS Digital APM JIRA Project. Here's a handy link to the ticket: CCM-7478 |
|
This branch is work on a ticket in the NHS Digital APM JIRA Project. Here's a handy link to the ticket: CCM-7478 |
|
This branch is work on a ticket in the NHS Digital APM JIRA Project. Here's a handy link to the ticket: CCM-7478 |
|
This branch is work on a ticket in the NHS Digital APM JIRA Project. Here's a handy link to the ticket: CCM-7478 |
|
This branch is work on a ticket in the NHS Digital APM JIRA Project. Here's a handy link to the ticket: CCM-7478 |
|
This branch is work on a ticket in the NHS Digital APM JIRA Project. Here's a handy link to the ticket: CCM-7478 |
* CCM-7478: Remove unnecessary sandbox dependency * CCM-7478: Configure test coverage reporting * CCM-7478: Don't set Node.js path for Sonar * CCM-7478: Make Sonar scan fail if quality gate fails
Summary
CCM-7478
This PR enables reporting of test coverage metrics in SonarCloud.
Changes:
Test sandbox serverstep of thebuildworkflow that use the lcov-result-merger package (as used in the nhs-notify-repository-template repository) to generate anlcov.infofile with the correct file paths for Sonar to interpretscripts/config/sonar-scanner.properties) to:mocha-multipackage from the sandbox applicationVerification
Verified in the build output that the

lcov.infofile is being read as part of the Sonar scan:Verified in the build output that the scan is waiting for the quality gate results:

(Also, see df79145 for a commit which was deliberately failing the quality gate.)
Verified that the Sonar dashboard is (attempting) to show coverage:


Note that the message given for another branch, without the changes in this PR tells us coverage reporting isn't enabled:
Reviews Required
Checklist